<?php

use yii\helpers\Html;
use yii\widgets\ActiveForm;

/**
 * @var yii\web\View $this
 * @var common\models\Location $model
 * @var yii\widgets\ActiveForm $form
 */
?>

<div class="location-form">
    <?php $form = ActiveForm::begin(); ?>
    <div class="row">
        <div class="col-md-6">


            <?= $form->field($model, 'category_id')->textInput() ?>

            <?= $form->field($model, 'subcategory_id')->textInput() ?>

            <?= $form->field($model, 'latitude')->textInput() ?>

            <?= $form->field($model, 'longitude')->textInput() ?>

            <?= $form->field($model, 'name')->textInput(['maxlength' => 255]) ?>

            <?= $form->field($model, 'description')->textarea(['rows' => 6]) ?>

        </div>
        <div class="col-md-6">

            <?= $form->field($model, 'address')->textInput(['maxlength' => 255]) ?>

            <?= $form->field($model, 'city')->textInput(['maxlength' => 255]) ?>

            <?= $form->field($model, 'phone')->textInput(['maxlength' => 255]) ?>

            <?= $form->field($model, 'mobile')->textInput(['maxlength' => 255]) ?>

            <?= $form->field($model, 'websitelink')->textInput(['maxlength' => 255]) ?>

            <?= $form->field($model, 'note')->textarea(['rows' => 6]) ?>


        </div>
    </div>
    <hr>
    <div class="row">
        <div class="form-group">
            <?= Html::submitButton($model->isNewRecord ? Yii::t('app', 'Create') : Yii::t('app', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success pull-right' : 'btn btn-primary pull-right']) ?>
        </div>
    </div>
    <?php ActiveForm::end(); ?>
</div>
